<!DOCTYPE html>
<html>
    <head>
        <title>Benchmark &mdash; Pathfinder</title>
        <meta charset="utf-8">
        {{>partials/header.html}}
        <script type="text/javascript" src="/js/pathfinder/benchmark.js"></script>
    </head>
    <body class="pf-unscrollable">
        {{>partials/navbar.html isTool=true}}
        <canvas id="pf-canvas" class="pf-draggable" width="400" height="300"></canvas>
        <div id="pf-nonoverlapping-bottom-bar"
         class="fixed-bottom mb-3 pt-3 d-flex justify-content-between align-items-end pf-pointer-events-none border border-right-0 border-bottom-0 border-left-0">
            <div class="container ml-3 pf-pointer-events-auto">
                <div class="row">
                    <label for="pf-aa-level-select" class="col-form-label">Antialiasing</label>
                    <div class="col-md-auto">
                        <select id="pf-aa-level-select" class="form-control custom-select">
                            <option value="none" selected>None</option>
                            <option value="ssaa-2">2&times;SSAA</option>
                            <option value="ssaa-4">4&times;SSAA</option>
                            <option value="ecaa">ECAA</option>
                        </select>
                    </div>
                </div>
            </div>
            <div id="pf-toolbar">
                <button id="pf-run-benchmark-button" type="button"
                 class="btn btn-primary pf-toolbar-button">
                    Run Benchmark
                </button>
            </div>
        </div>
        <div class="modal fade" id="pf-benchmark-results-modal" tabindex="-1" role="dialog"
         aria-labelledby="pf-benchmark-results-label" aria-hidden="true">
            <div class="modal-dialog" role="document">
                <div class="modal-content">
                    <div class="modal-header">
                        <h5 class="modal-title" id="pf-benchmark-result-label">
                            Benchmark Results
                        </h5>
                        <button type="button" class="close" data-dismiss="modal"
                         aria-label="Close">
                            <span aria-hidden="true">&times;</span>
                        </button>
                    </div>
                    <div class="modal-body">
                        <div class="pf-benchmark-results-global">
                            <span class="pf-benchmark-results-label">Partitioning:</span>
                            &nbsp;
                            <span id="pf-benchmark-results-partitioning-time">0</span> µs/glyph
                        </div>
                        <table class="table table-striped">
                            <thead class="thead-default">
                                <tr><th>Font size (px)</th><th>GPU time per glyph (µs)</th></tr>
                            </thead>
                            <tbody id="pf-benchmark-results-table-body"></tbody>
                        </table>
                    </div>
                    <div class="modal-footer">
                        <button type="button" class="btn btn-secondary"
                         id="pf-benchmark-results-save-csv-button">Save CSV&hellip;</button>
                        <button type="button" class="btn btn-primary"
                         id="pf-benchmark-results-close-button">Close</button>
                    </div>
                </div>
            </div>
        </div>
    </body>
</html>

